package cn.sykj.car.entity;

import cn.sykj.car.utils.DiffEntity;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableLogic;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

import java.io.Serializable;
import java.util.Date;

/**
 * <p>
 * 充值设置
 * </p>
 *
 * @author xuming
 * @since 2021-06-25
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@ApiModel(value="ConfigRecharge对象", description="充值设置")
public class ConfigRecharge extends Model<ConfigRecharge> {

    private static final long serialVersionUID = 1L;

    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;

    @ApiModelProperty(value = "储值类型：1-固定金额 2-可变金额")
    @DiffEntity(action = "储值类型变化")
    private Integer type;

    @ApiModelProperty(value = "固定充值金额或最低充值金额（非必填）")
    @DiffEntity(action = "固定充值金额或最低充值金额变化")
    private Integer rechargeAmount;

    @ApiModelProperty(value = "充值赠送金额")
    @DiffEntity(action = "充值赠送金额变化")
    private Integer rechargeSendAmount;

    @ApiModelProperty(value = "返现金额")
    @DiffEntity(action = "返现金额变化")
    private Integer sendCash;

    @ApiModelProperty(value = "返积分")
    @DiffEntity(action = "返积分变化")
    private Integer sendIntegral;

    @ApiModelProperty(value = "备注")
    @DiffEntity(action = "备注变化")
    private String remarks;

    @ApiModelProperty(value = "是否循环赠送：1-循环 0-不循环")
    @DiffEntity(action = "是否循环赠送变化")
    private Integer overflyFlag;

    private Date createTime;

    private Date updateTime;

    private String createUser;

    private String updateUser;

    @ApiModelProperty(value = "删除标记：0-正常  1-删除")
    @TableLogic
    private Integer delFlag;


    public static final String ID = "id";

    public static final String TYPE = "type";

    public static final String RECHARGE_AMOUNT = "recharge_amount";

    public static final String RECHARGE_SEND_AMOUNT = "recharge_send_amount";

    public static final String SEND_CASH = "send_cash";

    public static final String SEND_INTEGRAL = "send_integral";

    public static final String REMARKS = "remarks";

    public static final String OVERFLY_FLAG = "overfly_flag";

    public static final String CREATE_TIME = "create_time";

    public static final String UPDATE_TIME = "update_time";

    public static final String CREATE_USER = "create_user";

    public static final String UPDATE_USER = "update_user";

    public static final String DEL_FLAG = "del_flag";

    @Override
    protected Serializable pkVal() {
        return this.id;
    }

}
